from typing import Iterable, Mapping, Sequence

def cpu_count(logical: bool) -> int: ...
def process_iter() -> Iterable[Process]: ...

class Process:
    def as_dict(self, attrs: Sequence[str]) -> Mapping[str, object]: ...
    def name(self) -> str: ...
    def parent(self) -> Process: ...
    def kill(self) -> None: ...
    def is_running(self) -> bool: ...

class NoSuchProcess(BaseException):
    pass
